package com.linkhub.oms.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.extension.handlers.FastjsonTypeHandler;
import com.linkhub.oms.common.enums.mp.DataStatusEnum;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.io.Serializable;
import java.time.LocalDate;
import java.time.LocalDateTime;
import java.util.Map;

/**
 * <p>
 * 汇率表
 * </p>
 *
 * @author Frank
 * @since 2024-06-08
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName(value = "t_exchange_rate", autoResultMap = true)
@ApiModel(value = "ExchangeRateEntity对象", description = "汇率表")
public class ExchangeRateEntity implements Serializable {


    @ApiModelProperty(value = "主键")
    @TableId(value = "Fid", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "汇率")
    @TableField(value = "Fexchange_rate", typeHandler = FastjsonTypeHandler.class)
    private Map<String, String> exchangeRate;

    @ApiModelProperty(value = "汇率日期")
    @TableField("Frate_date")
    private LocalDate rateDate;

    @ApiModelProperty(value = "数据状态：1-有效；0-无效")
    @TableField("Fdata_status")
    private DataStatusEnum dataStatus;

    @ApiModelProperty(value = "创建时间")
    @TableField("Fcreated_time")
    private LocalDateTime createdTime;


}
